<meta charset="utf-8"/>
		<script src="../../js/mui.min.js"></script>
		<script src="../../js/index.js"></script>  
        <script type="text/javascript">
            
        mui.plusReady(function() { 
        	// 隐藏滚动条
            plus.webview.currentWebview().setStyle({scrollIndicator:'none'});
		  	var self = plus.webview.currentWebview();
      		var user_id= self.user_id;
      		if(user_id == undefined){
      			user_id = '';
      		}
      		mui.ajax({ //ajax请求
					url: getServerIp + 'AppCourse/myApplication',
					type: 'GET', 
					data: {
						id:user_id
					}, //传参 
					success: function(data, textStatus, jqXHR) {
						document.getElementById('applicationList').innerHTML = "";
						var table = document.body.querySelector('#applicationList');
					//	var obj = JSON.parse(data);
					var list =  data.userAppointment;
					if(list == null || list == ''){
						var li = document.createElement('li');
						li.innerHTML = "暂无数据"
						table.appendChild(li);
					}else{
						var list_count = list.length;
						for(var i = 0;i<list_count;i++){
						   var obj = list[i];
	    					var li = document.createElement('li');
	    					//新增id属性
	    					li.id = obj.id;//course_id
								li.className = 'mui-content2';
							li.innerHTML = '<ul class="mui-table-view mui-table-view-chevron" style="margin-bottom: 10px;">'+
							'<li>'+
							'<div style="width: 100%; height: 40px;line-height: 40px;border-bottom: 1px solid #eee;margin-bottom: 10px;padding: 0 15px;">'+
							obj.center_name+
							'<span style="float: right;color: #83e5ab;">'+obj.order_status+'</span>'+
							'</div></li>'+
							'<li class="mui-table-view-cell mui-media">'+
							'<a class="mui-navigate-right">'+
							'<img class="mui-media-object mui-pull-left" src="'+getServerIp+'/Public/Uploads/image/'+obj.image+'">'+
							'<div class="mui-media-body">'+
							obj.course_name+
							'<div style="padding-bottom: 10px;bottom: 0;position: absolute;">'+
							'<p class="mui-ellipsis" style="float: left;">下单日期&nbsp;'+obj.create_time+'</p>'+
							'</div></div></a></li></ul>';
	                        table.appendChild(li);
	                        
						}
					}
					//打开详情页
					var ls = document.getElementsByClassName('mui-content2');//与上面的li.className一致
					  	for(var i = 0;i<ls.length;i++){
					  		ls[i].addEventListener('tap', function() {
			               	mui.openWindow({
			                   	url: 'orderDetail.html', 
                   				id:'orderDetail',
			                   	extras: {
									type:this.getAttribute("id")
								},
	                     waiting:{
                            autoShow:false,//自动显示等待框，默认为true
                          }
			               });
					    });
					  }
					}
				})
      		
      		
      		
      		
//		    var list = document.getElementsByClassName('mui-table-view-cell');
//		  for(var i = 0;i<list.length;i++){
//		  	list[i].addEventListener('tap', function() {
//             mui.openWindow({
//                 url: 'orderDetail.html', 
//                 id:'orderDetail'
//             });
//		    });
//		  }
		  
        });
        
        </script>
		<link rel="stylesheet" href="../../css/mui.min.css">
		<style>
			html,
			body {
				background-color: #efeff4;
			}
			.mui-bar-nav~.mui-content {
				padding: 0;
			}
			.title {
				margin: 20px 15px 10px;
				color: #6d6d72;
				font-size: 15px;
			}
		</style>

<div class="mui-content" id="applicationList">
			<!--<ul class="mui-table-view mui-table-view-chevron" style="margin-bottom: 10px;">
				<li>
					<div style="width: 100%; height: 40px;line-height: 40px;border-bottom: 1px solid #eee;margin-bottom: 10px;padding: 0 15px;">
						南京JM Dance工作室
						<span style="float: right;color: #83e5ab;">已预约</span>
					</div>
				</li>
				<li class="mui-table-view-cell mui-media">
					<a class="mui-navigate-right">
						<img class="mui-media-object mui-pull-left" src="../../images/cbd.jpg">
						<div class="mui-media-body">
							南京JM Dance专业拉丁舞基础班一级
							<div style="padding-bottom: 10px;bottom: 0;position: absolute;">
							    <p class='mui-ellipsis' style="float: left;">下单日期&nbsp;2015-6-3</p>
							</div>
						</div>
					</a>
				</li>
			</ul>
			<ul class="mui-table-view mui-table-view-chevron" style="margin-bottom: 10px;">
				<li>
					<div style="width: 100%; height: 40px;line-height: 40px;border-bottom: 1px solid #eee;margin-bottom: 10px;padding: 0 15px;">
						南京JM Dance工作室
						<span style="float: right;color: #9a9a9a;">已完成</span>
					</div>
				</li>
				<li class="mui-table-view-cell mui-media">
					<a class="mui-navigate-right">
						<img class="mui-media-object mui-pull-left" src="../../images/cbd.jpg">
						<div class="mui-media-body">
							南京JM Dance专业拉丁舞基础班一级
							<div style="padding-bottom: 10px;bottom: 0;position: absolute;">
							    <p class='mui-ellipsis' style="float: left;">下单日期&nbsp;2015-6-3</p>
							</div>
						</div>
					</a>
				</li>
			</ul>
			<ul class="mui-table-view mui-table-view-chevron" style="margin-bottom: 10px;">
				<li>
					<div style="width: 100%; height: 40px;line-height: 40px;border-bottom: 1px solid #eee;margin-bottom: 10px;padding: 0 15px;">
						南京JM Dance工作室
						<span style="float: right;color: #83e5ab;">已预约</span>
					</div>
				</li>
				<li class="mui-table-view-cell mui-media">
					<a class="mui-navigate-right">
						<img class="mui-media-object mui-pull-left" src="../../images/cbd.jpg">
						<div class="mui-media-body">
							南京JM Dance专业拉丁舞基础班一级
							<div style="padding-bottom: 10px;bottom: 0;position: absolute;">
							    <p class='mui-ellipsis' style="float: left;">下单日期&nbsp;2015-6-3</p>
							</div>
						</div>
					</a>
				</li>
			</ul>
			<ul class="mui-table-view mui-table-view-chevron" style="margin-bottom: 10px;">
				<li>
					<div style="width: 100%; height: 40px;line-height: 40px;border-bottom: 1px solid #eee;margin-bottom: 10px;padding: 0 15px;">
						南京JM Dance工作室
						<span style="float: right;color: #9a9a9a;">已完成</span>
					</div>
				</li>
				<li class="mui-table-view-cell mui-media">
					<a class="mui-navigate-right">
						<img class="mui-media-object mui-pull-left" src="../../images/cbd.jpg">
						<div class="mui-media-body">
							南京JM Dance专业拉丁舞基础班一级
							<div style="padding-bottom: 10px;bottom: 0;position: absolute;">
							    <p class='mui-ellipsis' style="float: left;">下单日期&nbsp;2015-6-3</p>
							</div>
						</div>
					</a>
				</li>
			</ul>
			<ul class="mui-table-view mui-table-view-chevron" style="margin-bottom: 10px;">
				<li>
					<div style="width: 100%; height: 40px;line-height: 40px;border-bottom: 1px solid #eee;margin-bottom: 10px;padding: 0 15px;">
						南京JM Dance工作室
						<span style="float: right;color: #83e5ab;">已预约</span>
					</div>
				</li>
				<li class="mui-table-view-cell mui-media">
					<a class="mui-navigate-right">
						<img class="mui-media-object mui-pull-left" src="../../images/cbd.jpg">
						<div class="mui-media-body">
							南京JM Dance专业拉丁舞基础班一级
							<div style="padding-bottom: 10px;bottom: 0;position: absolute;">
							    <p class='mui-ellipsis' style="float: left;">下单日期&nbsp;2015-6-3</p>
							</div>
						</div>
					</a>
				</li>
			</ul>
			<ul class="mui-table-view mui-table-view-chevron" style="margin-bottom: 10px;">
				<li>
					<div style="width: 100%; height: 40px;line-height: 40px;border-bottom: 1px solid #eee;margin-bottom: 10px;padding: 0 15px;">
						南京JM Dance工作室
						<span style="float: right;color: #9a9a9a;">已完成</span>
					</div>
				</li>
				<li class="mui-table-view-cell mui-media">
					<a class="mui-navigate-right">
						<img class="mui-media-object mui-pull-left" src="../../images/cbd.jpg">
						<div class="mui-media-body">
							南京JM Dance专业拉丁舞基础班一级
							<div style="padding-bottom: 10px;bottom: 0;position: absolute;">
							    <p class='mui-ellipsis' style="float: left;">下单日期&nbsp;2015-6-3</p>
							</div>
						</div>
					</a>
				</li>
			</ul>
			<ul class="mui-table-view mui-table-view-chevron" style="margin-bottom: 10px;">
				<li>
					<div style="width: 100%; height: 40px;line-height: 40px;border-bottom: 1px solid #eee;margin-bottom: 10px;padding: 0 15px;">
						南京JM Dance工作室
						<span style="float: right;color: #83e5ab;">已预约</span>
					</div>
				</li>
				<li class="mui-table-view-cell mui-media">
					<a class="mui-navigate-right">
						<img class="mui-media-object mui-pull-left" src="../../images/cbd.jpg">
						<div class="mui-media-body">
							南京JM Dance专业拉丁舞基础班一级
							<div style="padding-bottom: 10px;bottom: 0;position: absolute;">
							    <p class='mui-ellipsis' style="float: left;">下单日期&nbsp;2015-6-3</p>
							</div>
						</div>
					</a>
				</li>
			</ul>
			<ul class="mui-table-view mui-table-view-chevron" style="margin-bottom: 10px;">
				<li>
					<div style="width: 100%; height: 40px;line-height: 40px;border-bottom: 1px solid #eee;margin-bottom: 10px;padding: 0 15px;">
						南京JM Dance工作室
						<span style="float: right;color: #9a9a9a;">已完成</span>
					</div>
				</li>
				<li class="mui-table-view-cell mui-media">
					<a class="mui-navigate-right">
						<img class="mui-media-object mui-pull-left" src="../../images/cbd.jpg">
						<div class="mui-media-body">
							南京JM Dance专业拉丁舞基础班一级
							<div style="padding-bottom: 10px;bottom: 0;position: absolute;">
							    <p class='mui-ellipsis' style="float: left;">下单日期&nbsp;2015-6-3</p>
							</div>
						</div>
					</a>
				</li>
			</ul>
			<ul class="mui-table-view mui-table-view-chevron" style="margin-bottom: 10px;">
				<li>
					<div style="width: 100%; height: 40px;line-height: 40px;border-bottom: 1px solid #eee;margin-bottom: 10px;padding: 0 15px;">
						南京JM Dance工作室
						<span style="float: right;color: #83e5ab;">已预约</span>
					</div>
				</li>
				<li class="mui-table-view-cell mui-media">
					<a class="mui-navigate-right">
						<img class="mui-media-object mui-pull-left" src="../../images/cbd.jpg">
						<div class="mui-media-body">
							南京JM Dance专业拉丁舞基础班一级
							<div style="padding-bottom: 10px;bottom: 0;position: absolute;">
							    <p class='mui-ellipsis' style="float: left;">下单日期&nbsp;2015-6-3</p>
							</div>
						</div>
					</a>
				</li>
			</ul>
			<ul class="mui-table-view mui-table-view-chevron" style="margin-bottom: 10px;">
				<li>
					<div style="width: 100%; height: 40px;line-height: 40px;border-bottom: 1px solid #eee;margin-bottom: 10px;padding: 0 15px;">
						南京JM Dance工作室
						<span style="float: right;color: #9a9a9a;">已完成</span>
					</div>
				</li>
				<li class="mui-table-view-cell mui-media">
					<a class="mui-navigate-right">
						<img class="mui-media-object mui-pull-left" src="../../images/cbd.jpg">
						<div class="mui-media-body">
							南京JM Dance专业拉丁舞基础班一级
							<div style="padding-bottom: 10px;bottom: 0;position: absolute;">
							    <p class='mui-ellipsis' style="float: left;">下单日期&nbsp;2015-6-3</p>
							</div>
						</div>
					</a>
				</li>
			</ul>-->
</div>

